<!DOCTYPE html>
<html>
	<head>
		<%include ../template/hmeta %>
	</head>	
	<body class="body-order">
		<header>
			<div class="user-header">
				<a href="javascript:;" class="h-left h-back"><span>返回</span></a>
				<h2>填写订单</h2>
				<a href="/" class="h-right h-home"><span>主页</span></a>
			</div>
		</header>

		<!-- order form -->
		<form id="form-order" action="/order/create" method="POST">
		<input type="hidden" name="addressID" value="<%=addr.id%>"/>
		<div class="box"> 
			<dl class="panel panel-default">
				<dt class="panel-heading">
					<span>收货人信息</span>
				</dt>
				<dd class="panel-body">
					<a href="/user/select_address">
						<span class="icon icon-arrow-right"></span>
						<p>
							<label><%=addr.name%></label><span class="addr-mobile"><%=addr.mobilephone%></span>
						</p>
						<p>
							<%=addressMap[addr.province]&&addressMap[addr.province][0]%><%=addressMap[addr.city]&&addressMap[addr.city][0]%><%if(addr.county!=-1){%><%=addressMap[addr.county]&&addressMap[addr.county][0]%><%}%>
							<%=addr.details%>
						</p>
					</a>
				</dd>
			</dl>
			<dl class="panel panel-default">
				<dt class="panel-heading">
					<span>支付方式</span>
				</dt>
				<dd class="panel-body">
					<label>
						<span class="icon icon-alipay"></span><span>支付宝</span>
					</label>
				</dd>
			</dl>
			<dl class="panel panel-default">
				<dt class="panel-heading">
					<span>订单金额</span>
				</dt>
				<dd class="panel-body">
					<ul class="order-summary">
						<li><label>商品金额：</label><span>￥<%=cart.price*cart.count%></span></li>
						<li><label>商品运费：</label><span>￥<%=cart.freight%></span></li>
						<li><label>应付金额：</label><span class="total">￥<%=cart.price*cart.count%></span></li>
					</ul>
				</dd>
			</dl>	
		</div>

		<div class="nav-fixed-bottom bg-red">
			<a href="javascript:;" class="btn-lg btn-submit">提交</a>
			<p class="total">总金额<span>￥<%=cart.price*cart.count%></span></p>
			<p>为您节省<span>￥<%=(cart.oriPrice-cart.price)*cart.count%></span></p>
		</div>
		</form>

	</body>
</html>